package com.sqx.modules.evaluate.dao;

import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.baomidou.mybatisplus.core.metadata.IPage;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.sqx.modules.evaluate.entity.SysEvaluate;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;

import java.math.BigDecimal;

/**
 * <p>
 *  Mapper 接口
 * </p>
 *
 * @author wuchang
 * @since 2022-11-10
 */
@Mapper
public interface SysEvaluateDao extends BaseMapper<SysEvaluate> {

    String getTotalScore(@Param("userId") Long userId);

    IPage<SysEvaluate> getUserEvaluateList(@Param("pages") Page<SysEvaluate> pages, @Param("evaluate") SysEvaluate evaluate);

    BigDecimal selectCommentOrderScoreByUserId(Long userId,String startTime,String endTime);

    Integer selectCommentOrderCountByUserId(Long userId,String startTime,String endTime);

}
